# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
# RUN: llc -x mir -o - %s -run-pass=greedy -verify-regalloc 2>&1 | FileCheck %s

# CHECK-NOT: Bad Parent VNI
--- |
  ; ModuleID = './statepoint-invoke-ra2.ll'
  source_filename = "./statepoint-invoke-ra2.ll"
  target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
  target triple = "x86_64-unknown-linux-gnu"

  @global = external global ptr addrspace(1), align 8
  @global.1 = external global ptr addrspace(1), align 8

  define void @bar(ptr addrspace(1) %arg) gc "statepoint-example" personality ptr @zot {
  bb:
    %tmp = inttoptr i64 undef to ptr addrspace(1)
    br label %bb1

  bb1:                                              ; preds = %bb64, %bb
    %tmp3 = call token (i64, i32, ptr, i32, i32, ...) @llvm.experimental.gc.statepoint.p0(i64 2, i32 5, ptr nonnull elementtype(void ()) @wibble, i32 0, i32 0, i32 0, i32 0) [ "deopt"(i32 0, i32 2, i32 0, i32 0, i32 0, i32 1, i32 0, i32 7, ptr null, i32 2, i32 1, i32 0, i32 0, i32 5, i32 0, i32 7, ptr null, i32 7, ptr null, i32 7, ptr null, i32 7, ptr null, i32 7, ptr null), "gc-live"(ptr addrspace(1) %tmp) ]
    %tmp4 = call coldcc ptr addrspace(1) @llvm.experimental.gc.relocate.p1(token %tmp3, i32 0, i32 0) ; (%tmp, %tmp)
    %tmp5 = call token (i64, i32, ptr, i32, i32, ...) @llvm.experimental.gc.statepoint.p0(i64 2882400000, i32 0, ptr nonnull elementtype(void (ptr addrspace(1))) @barney, i32 1, i32 0, ptr addrspace(1) undef, i32 0, i32 0) [ "deopt"(i32 0, i32 2, i32 0, i32 0, i32 0, i32 1, i32 0, i32 7, ptr null, i32 9, i32 1, i32 9, i32 0, i32 5, i32 1, i32 7, ptr null, i32 8, i32 2, i32 7, ptr null, i32 7, ptr null, i32 7, ptr null, i32 8, i32 2), "gc-live"(ptr addrspace(1) undef, ptr addrspace(1) %tmp4) ]
    %tmp6 = call coldcc ptr addrspace(1) @llvm.experimental.gc.relocate.p1(token %tmp5, i32 1, i32 1) ; (%tmp4, %tmp4)
    %tmp7 = call token (i64, i32, ptr addrspace(1) ()*, i32, i32, ...) @llvm.experimental.gc.statepoint.p0(i64 2, i32 5, ptr addrspace(1) ()* nonnull elementtype(ptr addrspace(1) ()) @blam, i32 0, i32 0, i32 0, i32 0) [ "deopt"(i32 0, i32 2, i32 0, i32 0, i32 0, i32 1, i32 0, i32 7, ptr null, i32 10, i32 1, i32 9, i32 0, i32 5, i32 1, i32 7, ptr null, i32 8, i32 2, i32 7, ptr null, i32 7, ptr null, i32 7, ptr null, i32 8, i32 2), "gc-live"(ptr addrspace(1) %tmp6, ptr addrspace(1) undef) ]
    %tmp8 = call align 8 "java-type-kid"="69" ptr addrspace(1) @llvm.experimental.gc.result.p1(token %tmp7)
    %tmp9 = call coldcc ptr addrspace(1) @llvm.experimental.gc.relocate.p1(token %tmp7, i32 0, i32 0) ; (%tmp6, %tmp6)
    br i1 undef, label %bb64, label %bb10

  bb10:                                             ; preds = %bb1
    %tmp11 = inttoptr i64 undef to ptr addrspace(1)
    %tmp12 = call ptr addrspace(1) @wobble.3(ptr addrspace(1) undef, ptr addrspace(1) undef)
    %tmp13 = select i1 false, ptr addrspace(1) null, ptr addrspace(1) %tmp12
    %tmp14 = extractvalue { i32, i1 } undef, 1
    br i1 %tmp14, label %bb17, label %bb15

  bb15:                                             ; preds = %bb10
    %tmp16 = call token (i64, i32, ptr, i32, i32, ...) @llvm.experimental.gc.statepoint.p0(i64 2882400000, i32 0, ptr nonnull elementtype(void (ptr addrspace(1))) @barney, i32 1, i32 0, ptr addrspace(1) undef, i32 0, i32 0) [ "deopt"(i32 0, i32 2, i32 0, i32 0, i32 0, i32 1, i32 0, i32 7, ptr null, i32 2, i32 1, i32 71, i32 0, i32 5, i32 0, i32 0, ptr addrspace(1) %tmp13, i32 7, ptr null, i32 7, ptr null, i32 7, ptr null, i32 7, ptr null, i32 2, i32 5, i32 1, i32 0, i32 2, i32 0, i32 0, ptr addrspace(1) %tmp8, i32 7, ptr null, i32 1, i32 6, i32 0, i32 0, i32 1, i32 1, i32 0, ptr addrspace(1) %tmp8, i32 8, i32 10), "gc-live"(ptr addrspace(1) %tmp9, ptr addrspace(1) %tmp13, ptr addrspace(1) %tmp11, ptr addrspace(1) undef, ptr addrspace(1) %tmp8) ]
    unreachable

  bb17:                                             ; preds = %bb10
    %tmp18 = load atomic i32, ptr addrspace(1) undef unordered, align 4
    %tmp19 = and i32 %tmp18, 33554431
    %tmp20 = invoke token (i64, i32, ptr, i32, i32, ...) @llvm.experimental.gc.statepoint.p0(i64 1, i32 16, ptr nonnull elementtype(void (i32, ptr addrspace(1))) @spam, i32 2, i32 0, i32 %tmp19, ptr addrspace(1) nonnull undef, i32 0, i32 0) [ "deopt"(i32 0, i32 2, i32 0, i32 0, i32 0, i32 1, i32 0, i32 7, ptr null, i32 2, i32 1, i32 71, i32 0, i32 5, i32 0, i32 0, ptr addrspace(1) %tmp13, i32 7, ptr null, i32 7, ptr null, i32 7, ptr null, i32 7, ptr null, i32 8, i32 5, i32 12, i32 0, i32 2, i32 0, i32 0, ptr addrspace(1) %tmp8, i32 7, ptr null), "gc-live"(ptr addrspace(1) %tmp9, ptr addrspace(1) %tmp13, ptr addrspace(1) %tmp13, ptr addrspace(1) %tmp11, ptr addrspace(1) %tmp8, ptr addrspace(1) undef) ]
            to label %bb21 unwind label %bb59

  bb21:                                             ; preds = %bb17
    %tmp22 = call coldcc ptr addrspace(1) @llvm.experimental.gc.relocate.p1(token %tmp20, i32 0, i32 0) ; (%tmp9, %tmp9)
    %tmp23 = call coldcc ptr addrspace(1) @llvm.experimental.gc.relocate.p1(token %tmp20, i32 1, i32 1) ; (%tmp13, %tmp13)
    %tmp24 = call coldcc ptr addrspace(1) @llvm.experimental.gc.relocate.p1(token %tmp20, i32 3, i32 3) ; (%tmp11, %tmp11)
    %tmp25 = load atomic ptr addrspace(1), ptr @global unordered, align 8
    %tmp26 = ptrtoint ptr addrspace(1) %tmp25 to i64
    %tmp27 = xor i64 %tmp26, -1
    %tmp28 = inttoptr i64 %tmp27 to ptr addrspace(1)
    %tmp29 = call token (i64, i32, ptr, i32, i32, ...) @llvm.experimental.gc.statepoint.p0(i64 2, i32 5, ptr nonnull elementtype(void (ptr addrspace(1))) @baz, i32 1, i32 0, ptr addrspace(1) undef, i32 0, i32 0) [ "deopt"(i32 0, i32 2, i32 0, i32 0, i32 0, i32 1, i32 0, i32 7, ptr null, i32 10, i32 1, i32 83, i32 0, i32 5, i32 1, i32 0, ptr addrspace(1) %tmp23, i32 7, ptr null, i32 8, i32 2, i32 7, ptr null, i32 7, ptr null, i32 8, i32 2), "gc-live"(ptr addrspace(1) %tmp22, ptr addrspace(1) %tmp23, ptr addrspace(1) %tmp23, ptr addrspace(1) %tmp24, ptr addrspace(1) %tmp28) ]
    %tmp30 = call coldcc ptr addrspace(1) @llvm.experimental.gc.relocate.p1(token %tmp29, i32 1, i32 2) ; (%tmp23, %tmp23)
    %tmp31 = call coldcc ptr addrspace(1) @llvm.experimental.gc.relocate.p1(token %tmp29, i32 4, i32 4) ; (%tmp28, %tmp28)
    %tmp45 = load atomic ptr addrspace(1), ptr @global.1 unordered, align 8
    %tmp49 = load i32, ptr addrspace(256) inttoptr (i64 660 to ptr addrspace(256)), align 4
    %tmp32 = icmp eq ptr addrspace(1) %tmp30, null
    br i1 %tmp32, label %bb64, label %bb33.preheader

  bb33.preheader:                                   ; preds = %bb21
    br label %bb33

  bb33:                                             ; preds = %bb33.preheader, %bb33
    %tmp34 = phi ptr addrspace(1) [ %tmp57, %bb33 ], [ undef, %bb33.preheader ]
    %tmp35 = phi i64 [ %tmp37, %bb33 ], [ 0, %bb33.preheader ]
    %tmp37 = add nuw nsw i64 %tmp35, 1
    %tmp38 = load atomic ptr addrspace(1), ptr addrspace(1) undef unordered, align 8
    %tmp39 = ptrtoint ptr addrspace(1) %tmp38 to i64
    %tmp40 = xor i64 %tmp39, -1
    %tmp41 = inttoptr i64 %tmp40 to ptr addrspace(1)
    %tmp42 = select i1 false, ptr addrspace(1) null, ptr addrspace(1) %tmp41
    %tmp43 = icmp eq ptr addrspace(1) %tmp42, %tmp30
    %tmp44 = select i1 %tmp43, ptr addrspace(1) null, ptr addrspace(1) %tmp42
    call void asm sideeffect "lock btsq $0,($1)", "r,r,~{cc},~{dirflag},~{fpsr},~{flags}"(i64 0, ptr undef)
    %tmp46 = ptrtoint ptr addrspace(1) %tmp45 to i64
    %tmp47 = xor i64 %tmp46, -1
    %tmp48 = inttoptr i64 %tmp47 to ptr addrspace(1)
    %tmp50 = or i32 %tmp49, 268435456
    %tmp51 = cmpxchg ptr addrspace(1) undef, i32 undef, i32 %tmp50 acquire monotonic, align 4
    call void @wobble(ptr addrspace(1) nonnull %tmp48)
    %tmp52 = load atomic ptr addrspace(1), ptr @global unordered, align 8
    %tmp53 = ptrtoint ptr addrspace(1) %tmp52 to i64
    %tmp54 = xor i64 %tmp53, -1
    %tmp55 = inttoptr i64 %tmp54 to ptr addrspace(1)
    %tmp56 = call token (i64, i32, ptr, i32, i32, ...) @llvm.experimental.gc.statepoint.p0(i64 2, i32 5, ptr nonnull elementtype(void (ptr addrspace(1))) @baz, i32 1, i32 0, ptr addrspace(1) %tmp55, i32 0, i32 0) [ "deopt"(i32 0, i32 2, i32 0, i32 0, i32 0, i32 1, i32 0, i32 7, ptr null, i32 10, i32 1, i32 83, i32 0, i32 5, i32 1, i32 0, ptr addrspace(1) %tmp44, i32 7, ptr null, i32 8, i32 2, i32 7, ptr null, i32 7, ptr null, i32 8, i32 2), "gc-live"(ptr addrspace(1) undef, ptr addrspace(1) %tmp44, ptr addrspace(1) %tmp44, ptr addrspace(1) %tmp34, ptr addrspace(1) undef) ]
    %tmp57 = call coldcc ptr addrspace(1) @llvm.experimental.gc.relocate.p1(token %tmp56, i32 3, i32 3) ; (%tmp34, %tmp34)
    br label %bb33

  bb59:                                             ; preds = %bb17
    %tmp60 = landingpad token
            cleanup
    %tmp61 = call coldcc ptr addrspace(1) @llvm.experimental.gc.relocate.p1(token %tmp60, i32 1, i32 2) ; (%tmp13, %tmp13)
    %tmp62 = call coldcc ptr addrspace(1) @llvm.experimental.gc.relocate.p1(token %tmp60, i32 4, i32 4) ; (%tmp8, %tmp8)
    %tmp63 = call token (i64, i32, ptr, i32, i32, ...) @llvm.experimental.gc.statepoint.p0(i64 2882400000, i32 0, ptr elementtype(void (i32)) @barney.2, i32 1, i32 2, i32 -13, i32 0, i32 0) [ "deopt"(i32 0, i32 2, i32 0, i32 0, i32 0, i32 1, i32 0, i32 7, ptr null, i32 2, i32 1, i32 71, i32 0, i32 5, i32 0, i32 0, ptr addrspace(1) %tmp61, i32 7, ptr null, i32 7, ptr null, i32 7, ptr null, i32 7, ptr null, i32 1, i32 5, i32 21, i32 0, i32 2, i32 0, i32 0, ptr addrspace(1) %tmp62, i32 0, ptr addrspace(1) undef), "gc-live"() ]
    unreachable

  bb64:                                             ; preds = %bb21, %bb1
    %tmp65 = or i32 undef, 268435456
    %tmp66 = cmpxchg ptr addrspace(1) undef, i32 undef, i32 %tmp65 acquire monotonic, align 4
    %tmp67 = call token (i64, i32, ptr, i32, i32, ...) @llvm.experimental.gc.statepoint.p0(i64 2, i32 5, ptr nonnull elementtype(void (ptr addrspace(1))) @baz, i32 1, i32 0, ptr addrspace(1) undef, i32 0, i32 0) [ "deopt"(i32 0, i32 2, i32 0, i32 0, i32 0, i32 1, i32 0, i32 7, ptr null, i32 10, i32 1, i32 133, i32 0, i32 5, i32 1, i32 7, ptr null, i32 8, i32 2, i32 7, ptr null, i32 7, ptr null, i32 7, ptr null, i32 8, i32 2), "gc-live"(ptr addrspace(1) undef, ptr addrspace(1) undef) ]
    br label %bb1
  }

  declare ptr @zot()

  declare void @wibble() gc "statepoint-example"

  declare ptr addrspace(1) @blam() gc "statepoint-example"

  declare void @baz(ptr addrspace(1)) gc "statepoint-example"

  declare void @spam(i32, ptr addrspace(1))

  declare void @wobble(ptr addrspace(1))

  declare void @barney(ptr addrspace(1))

  declare token @llvm.experimental.gc.statepoint.p0(i64 immarg, i32 immarg, ptr, i32 immarg, i32 immarg, ...)

  ; Function Attrs: nounwind readnone
  declare ptr addrspace(1) @llvm.experimental.gc.relocate.p1(token, i32 immarg, i32 immarg) #0

  
  
  ; Function Attrs: nounwind readnone
  declare ptr addrspace(1) @llvm.experimental.gc.result.p1(token) #0

  
  declare void @barney.2(i64)

  
  declare ptr addrspace(1) @wobble.3(ptr addrspace(1), ptr addrspace(1))

  attributes #0 = { nounwind readnone }

...
---
name:            bar
alignment:       16
exposesReturnsTwice: false
legalized:       false
regBankSelected: false
selected:        false
failedISel:      false
tracksRegLiveness: true
hasWinCFI:       false
registers:
  - { id: 0, class: gr64, preferred-register: '' }
  - { id: 1, class: gr64, preferred-register: '' }
  - { id: 2, class: gr64, preferred-register: '' }
  - { id: 3, class: gr64, preferred-register: '' }
  - { id: 4, class: gr64, preferred-register: '' }
  - { id: 5, class: gr64, preferred-register: '' }
  - { id: 6, class: gr64, preferred-register: '' }
  - { id: 7, class: gr32, preferred-register: '' }
  - { id: 8, class: gr64, preferred-register: '' }
  - { id: 9, class: gr64, preferred-register: '' }
  - { id: 10, class: gr64, preferred-register: '' }
  - { id: 11, class: gr64, preferred-register: '' }
  - { id: 12, class: gr64, preferred-register: '' }
  - { id: 13, class: gr64, preferred-register: '' }
  - { id: 14, class: gr64, preferred-register: '' }
  - { id: 15, class: gr64, preferred-register: '' }
  - { id: 16, class: gr64, preferred-register: '' }
  - { id: 17, class: gr64, preferred-register: '' }
  - { id: 18, class: gr64, preferred-register: '' }
  - { id: 19, class: gr64, preferred-register: '' }
  - { id: 20, class: gr32, preferred-register: '' }
  - { id: 21, class: gr8, preferred-register: '' }
  - { id: 22, class: gr64, preferred-register: '' }
  - { id: 23, class: gr64, preferred-register: '' }
  - { id: 24, class: gr64, preferred-register: '' }
  - { id: 25, class: gr32, preferred-register: '' }
  - { id: 26, class: gr8, preferred-register: '' }
  - { id: 27, class: gr64, preferred-register: '' }
  - { id: 28, class: gr64, preferred-register: '' }
  - { id: 29, class: gr64, preferred-register: '' }
  - { id: 30, class: gr64, preferred-register: '' }
  - { id: 31, class: gr64, preferred-register: '' }
  - { id: 32, class: gr64, preferred-register: '' }
  - { id: 33, class: gr64, preferred-register: '' }
  - { id: 34, class: gr32, preferred-register: '' }
  - { id: 35, class: gr64, preferred-register: '' }
  - { id: 36, class: gr32, preferred-register: '' }
  - { id: 37, class: gr64, preferred-register: '' }
  - { id: 38, class: gr64, preferred-register: '' }
  - { id: 39, class: gr64, preferred-register: '' }
  - { id: 40, class: gr64, preferred-register: '' }
  - { id: 41, class: gr32, preferred-register: '' }
  - { id: 42, class: gr64, preferred-register: '' }
  - { id: 43, class: gr64, preferred-register: '' }
  - { id: 44, class: gr64, preferred-register: '' }
  - { id: 45, class: gr64, preferred-register: '' }
  - { id: 46, class: gr64, preferred-register: '' }
  - { id: 47, class: gr64, preferred-register: '' }
  - { id: 48, class: gr64, preferred-register: '' }
  - { id: 49, class: gr64, preferred-register: '' }
  - { id: 50, class: gr64, preferred-register: '' }
  - { id: 51, class: gr64, preferred-register: '' }
  - { id: 52, class: gr64, preferred-register: '' }
  - { id: 53, class: gr64_with_sub_8bit, preferred-register: '' }
  - { id: 54, class: gr32, preferred-register: '' }
  - { id: 55, class: gr64_with_sub_8bit, preferred-register: '' }
  - { id: 56, class: gr64, preferred-register: '' }
  - { id: 57, class: gr64, preferred-register: '' }
  - { id: 58, class: gr64, preferred-register: '' }
  - { id: 59, class: gr64, preferred-register: '' }
  - { id: 60, class: gr64, preferred-register: '' }
  - { id: 61, class: gr32, preferred-register: '' }
  - { id: 62, class: gr64, preferred-register: '' }
  - { id: 63, class: gr64, preferred-register: '' }
  - { id: 64, class: gr64, preferred-register: '' }
  - { id: 65, class: gr32, preferred-register: '' }
  - { id: 66, class: gr32, preferred-register: '' }
  - { id: 67, class: gr64, preferred-register: '' }
  - { id: 68, class: gr32, preferred-register: '' }
  - { id: 69, class: gr64, preferred-register: '' }
  - { id: 70, class: gr64, preferred-register: '' }
  - { id: 71, class: gr64, preferred-register: '' }
  - { id: 72, class: gr64, preferred-register: '' }
  - { id: 73, class: gr64, preferred-register: '' }
  - { id: 74, class: gr32, preferred-register: '' }
  - { id: 75, class: gr32, preferred-register: '' }
  - { id: 76, class: gr64, preferred-register: '' }
  - { id: 77, class: gr32, preferred-register: '' }
  - { id: 78, class: gr64, preferred-register: '' }
  - { id: 79, class: gr64, preferred-register: '' }
  - { id: 80, class: gr64, preferred-register: '' }
  - { id: 81, class: gr64_with_sub_8bit, preferred-register: '' }
liveins:         []
frameInfo:
  isFrameAddressTaken: false
  isReturnAddressTaken: false
  hasStackMap:     false
  hasPatchPoint:   false
  stackSize:       0
  offsetAdjustment: 0
  maxAlignment:    1
  adjustsStack:    false
  hasCalls:        true
  stackProtector:  ''
  maxCallFrameSize: 4294967295
  cvBytesOfCalleeSavedRegisters: 0
  hasOpaqueSPAdjustment: false
  hasVAStart:      false
  hasMustTailInVarArgFunc: false
  hasTailCall:     false
  localFrameSize:  0
  savePoint:       ''
  restorePoint:    ''
fixedStack:      []
stack:           []
callSites:       []
debugValueSubstitutions: []
constants:       []
machineFunctionInfo: {}
body:             |
  ; CHECK-LABEL: name: bar
  ; CHECK: bb.0.bb:
  ; CHECK-NEXT:   successors: %bb.1(0x80000000)
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT:   [[MOV32r0_:%[0-9]+]]:gr32 = MOV32r0 implicit-def dead $eflags
  ; CHECK-NEXT:   [[MOV32ri:%[0-9]+]]:gr32 = MOV32ri -1
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT: bb.1.bb1:
  ; CHECK-NEXT:   successors: %bb.9(0x40000000), %bb.2(0x40000000)
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT:   ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   [[STATEPOINT:%[0-9]+]]:gr64 = STATEPOINT 2, 5, 0, undef %16:gr64, 2, 0, 2, 0, 2, 25, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 2, 2, 1, 2, 0, 2, 0, 2, 5, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 1, undef [[STATEPOINT]](tied-def 0), 2, 0, 2, 1, 0, 0, csr_64, implicit-def $rsp, implicit-def $ssp
  ; CHECK-NEXT:   ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   [[STATEPOINT1:%[0-9]+]]:gr64 = STATEPOINT 2882400000, 0, 1, target-flags(x86-plt) @barney, undef $rdi, 2, 0, 2, 0, 2, 27, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 9, 2, 1, 2, 9, 2, 0, 2, 5, 2, 1, 2, 7, 2, 0, 2, 8, 2, 2, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 8, 2, 2, 2, 1, [[STATEPOINT1]](tied-def 0), 2, 0, 2, 1, 0, 0, csr_64, implicit-def $rsp, implicit-def $ssp
  ; CHECK-NEXT:   ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   [[STATEPOINT1:%[0-9]+]]:gr64 = STATEPOINT 2, 5, 0, undef %18:gr64, 2, 0, 2, 0, 2, 27, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 10, 2, 1, 2, 9, 2, 0, 2, 5, 2, 1, 2, 7, 2, 0, 2, 8, 2, 2, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 8, 2, 2, 2, 1, [[STATEPOINT1]](tied-def 0), 2, 0, 2, 1, 0, 0, csr_64, implicit-def $rsp, implicit-def $ssp, implicit-def $rax
  ; CHECK-NEXT:   ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   [[COPY:%[0-9]+]]:gr64 = COPY $rax
  ; CHECK-NEXT:   TEST8rr [[MOV32r0_]].sub_8bit, [[MOV32r0_]].sub_8bit, implicit-def $eflags
  ; CHECK-NEXT:   JCC_1 %bb.9, 5, implicit killed $eflags
  ; CHECK-NEXT:   JMP_1 %bb.2
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT: bb.2.bb10:
  ; CHECK-NEXT:   successors: %bb.4(0x80000000), %bb.3(0x00000000)
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT:   ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   CALL64pcrel32 target-flags(x86-plt) @wobble.3, csr_64, implicit $rsp, implicit $ssp, implicit undef $rdi, implicit undef $rsi, implicit-def $rsp, implicit-def $ssp, implicit-def $rax
  ; CHECK-NEXT:   ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   [[COPY1:%[0-9]+]]:gr64 = COPY $rax
  ; CHECK-NEXT:   TEST8rr [[MOV32r0_]].sub_8bit, [[MOV32r0_]].sub_8bit, implicit-def $eflags
  ; CHECK-NEXT:   JCC_1 %bb.4, 5, implicit killed $eflags
  ; CHECK-NEXT:   JMP_1 %bb.3
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT: bb.3.bb15:
  ; CHECK-NEXT:   successors: {{$}}
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT:   ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   dead [[COPY1]]:gr64, dead [[COPY]]:gr64 = STATEPOINT 2882400000, 0, 1, target-flags(x86-plt) @barney, undef $rdi, 2, 0, 2, 0, 2, 45, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 2, 2, 1, 2, 71, 2, 0, 2, 5, 2, 0, 2, 0, [[COPY1]], 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 2, 2, 5, 2, 1, 2, 0, 2, 2, 2, 0, 2, 0, [[COPY]], 2, 7, 2, 0, 2, 1, 2, 6, 2, 0, 2, 0, 2, 1, 2, 1, 2, 0, [[COPY]], 2, 8, 2, 10, 2, 2, [[COPY1]](tied-def 0), [[COPY]](tied-def 1), 2, 0, 2, 2, 0, 0, 1, 1, csr_64, implicit-def $rsp, implicit-def $ssp
  ; CHECK-NEXT:   ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT: bb.4.bb17:
  ; CHECK-NEXT:   successors: %bb.5(0x80000000), %bb.8(0x00000000)
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT:   [[MOV32rm:%[0-9]+]]:gr32 = MOV32rm undef %35:gr64, 1, $noreg, 0, $noreg :: (load unordered (s32) from `ptr addrspace(1) undef`, addrspace 1)
  ; CHECK-NEXT:   [[AND32ri:%[0-9]+]]:gr32 = AND32ri [[AND32ri]], 33554431, implicit-def dead $eflags
  ; CHECK-NEXT:   EH_LABEL <mcsymbol .Ltmp0>
  ; CHECK-NEXT:   ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   $edi = COPY [[AND32ri]]
  ; CHECK-NEXT:   [[COPY2:%[0-9]+]]:gr64 = COPY [[COPY1]]
  ; CHECK-NEXT:   dead %30:gr64, [[COPY2]]:gr64, dead [[STATEPOINT1]]:gr64, [[COPY]]:gr64 = STATEPOINT 1, 16, 2, undef %38:gr64, $edi, undef $rsi, 2, 0, 2, 0, 2, 35, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 2, 2, 1, 2, 71, 2, 0, 2, 5, 2, 0, 2, 0, [[COPY2]], 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 8, 2, 5, 2, 12, 2, 0, 2, 2, 2, 0, 2, 0, [[COPY]], 2, 7, 2, 0, 2, 4, undef %30(tied-def 0), [[COPY2]](tied-def 1), [[STATEPOINT1]](tied-def 2), [[COPY]](tied-def 3), 2, 0, 2, 4, 0, 0, 1, 1, 2, 2, 3, 3, csr_64, implicit-def $rsp, implicit-def $ssp
  ; CHECK-NEXT:   ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   EH_LABEL <mcsymbol .Ltmp1>
  ; CHECK-NEXT:   JMP_1 %bb.5
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT: bb.5.bb21:
  ; CHECK-NEXT:   successors: %bb.9(0x7c000000), %bb.6(0x04000000)
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT:   [[MOV64rm:%[0-9]+]]:gr64 = MOV64rm $rip, 1, $noreg, target-flags(x86-gotpcrel) @global, $noreg :: (load (s64) from got)
  ; CHECK-NEXT:   [[MOV64rm1:%[0-9]+]]:gr64 = MOV64rm [[MOV64rm]], 1, $noreg, 0, $noreg :: (dereferenceable load unordered (s64) from @global)
  ; CHECK-NEXT:   [[NOT64r:%[0-9]+]]:gr64 = NOT64r [[NOT64r]]
  ; CHECK-NEXT:   ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   dead [[NOT64r]]:gr64, [[COPY2]]:gr64 = STATEPOINT 2, 5, 1, undef %50:gr64, undef $rdi, 2, 0, 2, 0, 2, 27, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 10, 2, 1, 2, 83, 2, 0, 2, 5, 2, 1, 2, 0, [[COPY2]], 2, 7, 2, 0, 2, 8, 2, 2, 2, 7, 2, 0, 2, 7, 2, 0, 2, 8, 2, 2, 2, 2, [[NOT64r]](tied-def 0), [[COPY2]](tied-def 1), 2, 0, 2, 2, 0, 0, 1, 1, csr_64, implicit-def $rsp, implicit-def $ssp
  ; CHECK-NEXT:   ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   TEST64rr [[COPY2]], [[COPY2]], implicit-def $eflags
  ; CHECK-NEXT:   [[COPY3:%[0-9]+]]:gr64 = COPY [[COPY2]]
  ; CHECK-NEXT:   JCC_1 %bb.9, 4, implicit killed $eflags
  ; CHECK-NEXT:   JMP_1 %bb.6
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT: bb.6.bb33.preheader:
  ; CHECK-NEXT:   successors: %bb.7(0x80000000)
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT:   [[MOV64rm1:%[0-9]+]]:gr64 = MOV64rm $rip, 1, $noreg, target-flags(x86-gotpcrel) @global.1, $noreg :: (load (s64) from got)
  ; CHECK-NEXT:   [[MOV64rm2:%[0-9]+]]:gr64 = MOV64rm [[MOV64rm1]], 1, $noreg, 0, $noreg :: (dereferenceable load unordered (s64) from @global.1)
  ; CHECK-NEXT:   [[MOV32rm:%[0-9]+]]:gr32 = MOV32rm $noreg, 1, $noreg, 660, $gs :: (load (s32) from `ptr addrspace(256) inttoptr (i64 660 to ptr addrspace(256))`, addrspace 256)
  ; CHECK-NEXT:   [[NOT64r1:%[0-9]+]]:gr64 = NOT64r [[NOT64r1]]
  ; CHECK-NEXT:   [[COPY4:%[0-9]+]]:gr64 = COPY [[NOT64r1]]
  ; CHECK-NEXT:   [[OR32ri:%[0-9]+]]:gr32 = OR32ri [[OR32ri]], 268435456, implicit-def dead $eflags
  ; CHECK-NEXT:   [[COPY5:%[0-9]+]]:gr32 = COPY [[OR32ri]]
  ; CHECK-NEXT:   [[DEF:%[0-9]+]]:gr64 = IMPLICIT_DEF
  ; CHECK-NEXT:   [[COPY6:%[0-9]+]]:gr64 = COPY [[COPY3]]
  ; CHECK-NEXT:   undef %81.sub_32bit:gr64_with_sub_8bit = MOV32r0 implicit-def dead $eflags
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT: bb.7.bb33:
  ; CHECK-NEXT:   successors: %bb.7(0x80000000)
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT:   [[INC64r:%[0-9]+]]:gr64_with_sub_8bit = nuw nsw INC64r [[INC64r]], implicit-def dead $eflags
  ; CHECK-NEXT:   [[MOV64rm2:%[0-9]+]]:gr64 = MOV64rm undef %59:gr64, 1, $noreg, 0, $noreg :: (load unordered (s64) from `ptr addrspace(1) undef`, addrspace 1)
  ; CHECK-NEXT:   [[NOT64r2:%[0-9]+]]:gr64 = NOT64r [[NOT64r2]]
  ; CHECK-NEXT:   CMP64rr [[NOT64r2]], [[COPY6]], implicit-def $eflags
  ; CHECK-NEXT:   undef %100.sub_32bit:gr64_with_sub_8bit = MOV32ri 0
  ; CHECK-NEXT:   [[CMOV64rr:%[0-9]+]]:gr64 = CMOV64rr [[CMOV64rr]], %100, 4, implicit killed $eflags
  ; CHECK-NEXT:   INLINEASM &"lock btsq $0,($1)", 1 /* sideeffect attdialect */, 4521993 /* reguse:GR64 */, %100, 4521993 /* reguse:GR64 */, undef %56:gr64, 12 /* clobber */, implicit-def dead early-clobber $df, 12 /* clobber */, implicit-def early-clobber $fpsw, 12 /* clobber */, implicit-def dead early-clobber $eflags
  ; CHECK-NEXT:   LCMPXCHG32 undef %67:gr64, 1, $noreg, 0, $noreg, [[COPY5]], implicit-def dead $eax, implicit-def dead $eflags, implicit undef $eax :: (load store acquire monotonic (s32) on `ptr addrspace(1) undef`, addrspace 1)
  ; CHECK-NEXT:   ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   $rdi = COPY [[COPY4]]
  ; CHECK-NEXT:   CALL64pcrel32 target-flags(x86-plt) @wobble, csr_64, implicit $rsp, implicit $ssp, implicit $rdi, implicit-def $rsp, implicit-def $ssp
  ; CHECK-NEXT:   ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   [[MOV64rm2:%[0-9]+]]:gr64 = MOV64rm $rip, 1, $noreg, target-flags(x86-gotpcrel) @global, $noreg :: (load (s64) from got)
  ; CHECK-NEXT:   [[MOV64rm3:%[0-9]+]]:gr64 = MOV64rm [[MOV64rm2]], 1, $noreg, 0, $noreg :: (dereferenceable load unordered (s64) from @global)
  ; CHECK-NEXT:   [[NOT64r2:%[0-9]+]]:gr64 = NOT64r [[NOT64r2]]
  ; CHECK-NEXT:   ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   $rdi = COPY [[NOT64r2]]
  ; CHECK-NEXT:   [[DEF]]:gr64, dead [[CMOV64rr]]:gr64 = STATEPOINT 2, 5, 1, undef %73:gr64, $rdi, 2, 0, 2, 0, 2, 27, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 10, 2, 1, 2, 83, 2, 0, 2, 5, 2, 1, 2, 0, [[CMOV64rr]], 2, 7, 2, 0, 2, 8, 2, 2, 2, 7, 2, 0, 2, 7, 2, 0, 2, 8, 2, 2, 2, 2, [[DEF]](tied-def 0), [[CMOV64rr]](tied-def 1), 2, 0, 2, 2, 0, 0, 1, 1, csr_64, implicit-def $rsp, implicit-def $ssp
  ; CHECK-NEXT:   ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   JMP_1 %bb.7
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT: bb.8.bb59 (landing-pad):
  ; CHECK-NEXT:   successors:
  ; CHECK-NEXT:   liveins: $rax, $rdx
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT:   EH_LABEL <mcsymbol .Ltmp2>
  ; CHECK-NEXT:   ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   $edi = MOV32ri -13
  ; CHECK-NEXT:   dead [[COPY2]]:gr64, dead [[COPY]]:gr64 = STATEPOINT 2882400000, 0, 1, target-flags(x86-plt) @barney.2, $edi, 2, 0, 2, 2, 2, 35, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 2, 2, 1, 2, 71, 2, 0, 2, 5, 2, 0, 2, 0, [[COPY2]], 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 1, 2, 5, 2, 21, 2, 0, 2, 2, 2, 0, 2, 0, [[COPY]], 2, 0, 2, 4278124286, 2, 3, [[COPY2]](tied-def 0), [[COPY]](tied-def 1), 2, 4278124286, 2, 0, 2, 3, 0, 0, 1, 1, 2, 2, csr_64, implicit-def $rsp, implicit-def $ssp
  ; CHECK-NEXT:   ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT: bb.9.bb64:
  ; CHECK-NEXT:   successors: %bb.1(0x80000000)
  ; CHECK-NEXT: {{  $}}
  ; CHECK-NEXT:   LCMPXCHG32 undef %76:gr64, 1, $noreg, 0, $noreg, [[MOV32ri]], implicit-def dead $eax, implicit-def dead $eflags, implicit undef $eax :: (load store acquire monotonic (s32) on `ptr addrspace(1) undef`, addrspace 1)
  ; CHECK-NEXT:   ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   STATEPOINT 2, 5, 1, undef %79:gr64, undef $rdi, 2, 0, 2, 0, 2, 27, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 10, 2, 1, 2, 133, 2, 0, 2, 5, 2, 1, 2, 7, 2, 0, 2, 8, 2, 2, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 8, 2, 2, 2, 0, 2, 0, 2, 0, csr_64, implicit-def $rsp, implicit-def $ssp
  ; CHECK-NEXT:   ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
  ; CHECK-NEXT:   JMP_1 %bb.1
  bb.0.bb:
    successors: %bb.1(0x80000000)

    %20:gr32 = MOV32r0 implicit-def dead $eflags
    %74:gr32 = MOV32ri -1
    %46:gr64 = MOV64rm $rip, 1, $noreg, target-flags(x86-gotpcrel) @global, $noreg :: (load (s64) from got)
    %51:gr64 = MOV64rm $rip, 1, $noreg, target-flags(x86-gotpcrel) @global.1, $noreg :: (load (s64) from got)

  bb.1.bb1:
    successors: %bb.9(0x40000000), %bb.2(0x40000000)

    ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    %15:gr64 = STATEPOINT 2, 5, 0, undef %16:gr64, 2, 0, 2, 0, 2, 25, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 2, 2, 1, 2, 0, 2, 0, 2, 5, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 1, undef %15(tied-def 0), 2, 0, 2, 1, 0, 0, csr_64, implicit-def $rsp, implicit-def $ssp
    ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    %15:gr64 = STATEPOINT 2882400000, 0, 1, target-flags(x86-plt) @barney, undef $rdi, 2, 0, 2, 0, 2, 27, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 9, 2, 1, 2, 9, 2, 0, 2, 5, 2, 1, 2, 7, 2, 0, 2, 8, 2, 2, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 8, 2, 2, 2, 1, %15(tied-def 0), 2, 0, 2, 1, 0, 0, csr_64, implicit-def $rsp, implicit-def $ssp
    ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    %15:gr64 = STATEPOINT 2, 5, 0, undef %18:gr64, 2, 0, 2, 0, 2, 27, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 10, 2, 1, 2, 9, 2, 0, 2, 5, 2, 1, 2, 7, 2, 0, 2, 8, 2, 2, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 8, 2, 2, 2, 1, %15(tied-def 0), 2, 0, 2, 1, 0, 0, csr_64, implicit-def $rsp, implicit-def $ssp, implicit-def $rax
    ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    %33:gr64 = COPY $rax
    TEST8rr %20.sub_8bit, %20.sub_8bit, implicit-def $eflags
    JCC_1 %bb.9, 5, implicit killed $eflags
    JMP_1 %bb.2

  bb.2.bb10:
    successors: %bb.4(0x80000000), %bb.3(0x00000000)

    ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    CALL64pcrel32 target-flags(x86-plt) @wobble.3, csr_64, implicit $rsp, implicit $ssp, implicit undef $rdi, implicit undef $rsi, implicit-def $rsp, implicit-def $ssp, implicit-def $rax
    ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    %31:gr64 = COPY $rax
    TEST8rr %20.sub_8bit, %20.sub_8bit, implicit-def $eflags
    JCC_1 %bb.4, 5, implicit killed $eflags
    JMP_1 %bb.3

  bb.3.bb15:
    successors:

    ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    dead %31:gr64, dead %33:gr64 = STATEPOINT 2882400000, 0, 1, target-flags(x86-plt) @barney, undef $rdi, 2, 0, 2, 0, 2, 45, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 2, 2, 1, 2, 71, 2, 0, 2, 5, 2, 0, 2, 0, %31, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 2, 2, 5, 2, 1, 2, 0, 2, 2, 2, 0, 2, 0, %33, 2, 7, 2, 0, 2, 1, 2, 6, 2, 0, 2, 0, 2, 1, 2, 1, 2, 0, %33, 2, 8, 2, 10, 2, 2, %31(tied-def 0), %33(tied-def 1), 2, 0, 2, 2, 0, 0, 1, 1, csr_64, implicit-def $rsp, implicit-def $ssp
    ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp

  bb.4.bb17:
    successors: %bb.5(0x80000000), %bb.8(0x00000000)

    %36:gr32 = MOV32rm undef %35:gr64, 1, $noreg, 0, $noreg :: (load unordered (s32) from `ptr addrspace(1) undef`, addrspace 1)
    %36:gr32 = AND32ri %36, 33554431, implicit-def dead $eflags
    EH_LABEL <mcsymbol .Ltmp0>
    ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    $edi = COPY %36
    dead %30:gr64, %31:gr64, dead %15:gr64, %33:gr64 = STATEPOINT 1, 16, 2, undef %38:gr64, killed $edi, undef $rsi, 2, 0, 2, 0, 2, 35, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 2, 2, 1, 2, 71, 2, 0, 2, 5, 2, 0, 2, 0, %31, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 8, 2, 5, 2, 12, 2, 0, 2, 2, 2, 0, 2, 0, %33, 2, 7, 2, 0, 2, 4, undef %30(tied-def 0), %31(tied-def 1), %15(tied-def 2), %33(tied-def 3), 2, 0, 2, 4, 0, 0, 1, 1, 2, 2, 3, 3, csr_64, implicit-def $rsp, implicit-def $ssp
    ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    EH_LABEL <mcsymbol .Ltmp1>
    JMP_1 %bb.5

  bb.5.bb21:
    successors: %bb.9(0x7c000000), %bb.6(0x04000000)

    %44:gr64 = MOV64rm %46, 1, $noreg, 0, $noreg :: (dereferenceable load unordered (s64) from @global)
    %44:gr64 = NOT64r %44
    ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    dead %44:gr64, %31:gr64 = STATEPOINT 2, 5, 1, undef %50:gr64, undef $rdi, 2, 0, 2, 0, 2, 27, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 10, 2, 1, 2, 83, 2, 0, 2, 5, 2, 1, 2, 0, %31, 2, 7, 2, 0, 2, 8, 2, 2, 2, 7, 2, 0, 2, 7, 2, 0, 2, 8, 2, 2, 2, 2, %44(tied-def 0), %31(tied-def 1), 2, 0, 2, 2, 0, 0, 1, 1, csr_64, implicit-def $rsp, implicit-def $ssp
    ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    TEST64rr %31, %31, implicit-def $eflags
    JCC_1 %bb.9, 4, implicit killed $eflags
    JMP_1 %bb.6

  bb.6.bb33.preheader:
    successors: %bb.7(0x80000000)

    %64:gr64 = MOV64rm %51, 1, $noreg, 0, $noreg :: (dereferenceable load unordered (s64) from @global.1)
    %65:gr32 = MOV32rm $noreg, 1, $noreg, 660, $gs :: (load (s32) from `ptr addrspace(256) inttoptr (i64 660 to ptr addrspace(256))`, addrspace 256)
    undef %53.sub_32bit:gr64_with_sub_8bit = MOV32r0 implicit-def dead $eflags
    %64:gr64 = NOT64r %64
    %65:gr32 = OR32ri %65, 268435456, implicit-def dead $eflags
    %80:gr64 = IMPLICIT_DEF
    undef %81.sub_32bit:gr64_with_sub_8bit = MOV32r0 implicit-def dead $eflags

  bb.7.bb33:
    successors: %bb.7(0x80000000)

    %81:gr64_with_sub_8bit = nuw nsw INC64r %81, implicit-def dead $eflags
    %63:gr64 = MOV64rm undef %59:gr64, 1, $noreg, 0, $noreg :: (load unordered (s64) from `ptr addrspace(1) undef`, addrspace 1)
    %63:gr64 = NOT64r %63
    CMP64rr %63, %31, implicit-def $eflags
    %63:gr64 = CMOV64rr %63, %53, 4, implicit killed $eflags
    INLINEASM &"lock btsq $0,($1)", 1 /* sideeffect attdialect */, 4521993 /* reguse:GR64 */, %53, 4521993 /* reguse:GR64 */, undef %56:gr64, 12 /* clobber */, implicit-def dead early-clobber $df, 12 /* clobber */, implicit-def early-clobber $fpsw, 12 /* clobber */, implicit-def dead early-clobber $eflags
    LCMPXCHG32 undef %67:gr64, 1, $noreg, 0, $noreg, %65, implicit-def dead $eax, implicit-def dead $eflags, implicit undef $eax :: (load store acquire monotonic (s32) on `ptr addrspace(1) undef`, addrspace 1)
    ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    $rdi = COPY %64
    CALL64pcrel32 target-flags(x86-plt) @wobble, csr_64, implicit $rsp, implicit $ssp, implicit killed $rdi, implicit-def $rsp, implicit-def $ssp
    ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    %71:gr64 = MOV64rm %46, 1, $noreg, 0, $noreg :: (dereferenceable load unordered (s64) from @global)
    %71:gr64 = NOT64r %71
    ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    $rdi = COPY %71
    %80:gr64, dead %63:gr64 = STATEPOINT 2, 5, 1, undef %73:gr64, killed $rdi, 2, 0, 2, 0, 2, 27, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 10, 2, 1, 2, 83, 2, 0, 2, 5, 2, 1, 2, 0, %63, 2, 7, 2, 0, 2, 8, 2, 2, 2, 7, 2, 0, 2, 7, 2, 0, 2, 8, 2, 2, 2, 2, %80(tied-def 0), %63(tied-def 1), 2, 0, 2, 2, 0, 0, 1, 1, csr_64, implicit-def $rsp, implicit-def $ssp
    ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    JMP_1 %bb.7

  bb.8.bb59 (landing-pad):
    successors:
    liveins: $rax, $rdx

    EH_LABEL <mcsymbol .Ltmp2>
    ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    $edi = MOV32ri -13
    dead %31:gr64, dead %33:gr64 = STATEPOINT 2882400000, 0, 1, target-flags(x86-plt) @barney.2, killed $edi, 2, 0, 2, 2, 2, 35, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 2, 2, 1, 2, 71, 2, 0, 2, 5, 2, 0, 2, 0, %31, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 1, 2, 5, 2, 21, 2, 0, 2, 2, 2, 0, 2, 0, %33, 2, 0, 2, 4278124286, 2, 3, %31(tied-def 0), %33(tied-def 1), 2, 4278124286, 2, 0, 2, 3, 0, 0, 1, 1, 2, 2, csr_64, implicit-def $rsp, implicit-def $ssp
    ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp

  bb.9.bb64:
    successors: %bb.1(0x80000000)

    LCMPXCHG32 undef %76:gr64, 1, $noreg, 0, $noreg, %74, implicit-def dead $eax, implicit-def dead $eflags, implicit undef $eax :: (load store acquire monotonic (s32) on `ptr addrspace(1) undef`, addrspace 1)
    ADJCALLSTACKDOWN64 0, 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    STATEPOINT 2, 5, 1, undef %79:gr64, undef $rdi, 2, 0, 2, 0, 2, 27, 2, 0, 2, 2, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 2, 7, 2, 0, 2, 10, 2, 1, 2, 133, 2, 0, 2, 5, 2, 1, 2, 7, 2, 0, 2, 8, 2, 2, 2, 7, 2, 0, 2, 7, 2, 0, 2, 7, 2, 0, 2, 8, 2, 2, 2, 0, 2, 0, 2, 0, csr_64, implicit-def $rsp, implicit-def $ssp
    ADJCALLSTACKUP64 0, 0, implicit-def dead $rsp, implicit-def dead $eflags, implicit-def dead $ssp, implicit $rsp, implicit $ssp
    JMP_1 %bb.1

...
